//
//  HMSpringFlowersViewModel.m
//  HowToDo
//
//  Created by qu on 2017/1/5.
//  Copyright © 2017年 KY. All rights reserved.
//

#import "HMSpringFlowersViewModel.h"
#import "HMNetWorkTool.h"
#import <YYModel.h>

@interface HMSpringFlowersViewModel ()<YYModel>

@end

@implementation HMSpringFlowersViewModel

+ (void)loadSpringFlowersDataWithType:(NSInteger)type finishedBlock:(void(^)(id resultObject))finishBlock {
    
   [[HMNetWorkTool sharedTool] requestSpringFlowersJsonDataWithType:type Finished:^(id responseObject) {
     
       NSArray *dataArray = [NSArray yy_modelArrayWithClass:[HMSpringFlowersViewModel class] json:responseObject[@"data"]];
       finishBlock(dataArray);
       
   } Failed:^(NSError *error) {
     NSLog(@"%@",error);
       
   }];
}
+ (nullable NSDictionary<NSString *, id> *)modelCustomPropertyMapper {
    
    return @{@"tid":@"id"};
}


@end
